﻿using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using Google.Protobuf;
using Google.Protobuf.Collections;
using Google.Protobuf.Reflection;

namespace EggLink.DanhengServer.Proto
{
	// Token: 0x02000157 RID: 343
	[DebuggerDisplay("{ToString(),nq}")]
	public sealed class BuffInfo : IMessage<BuffInfo>, IMessage, IEquatable<BuffInfo>, IDeepCloneable<BuffInfo>, IBufferMessage
	{
		// Token: 0x17000498 RID: 1176
		// (get) Token: 0x06000F8A RID: 3978 RVA: 0x0002DDE8 File Offset: 0x0002BFE8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageParser<BuffInfo> Parser
		{
			get
			{
				return BuffInfo._parser;
			}
		}

		// Token: 0x17000499 RID: 1177
		// (get) Token: 0x06000F8B RID: 3979 RVA: 0x0002DDEF File Offset: 0x0002BFEF
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageDescriptor Descriptor
		{
			get
			{
				return BuffInfoReflection.Descriptor.MessageTypes[0];
			}
		}

		// Token: 0x1700049A RID: 1178
		// (get) Token: 0x06000F8C RID: 3980 RVA: 0x0002DE01 File Offset: 0x0002C001
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		MessageDescriptor IMessage.Descriptor
		{
			get
			{
				return BuffInfo.Descriptor;
			}
		}

		// Token: 0x06000F8D RID: 3981 RVA: 0x0002DE08 File Offset: 0x0002C008
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public BuffInfo()
		{
		}

		// Token: 0x06000F8E RID: 3982 RVA: 0x0002DE1C File Offset: 0x0002C01C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public BuffInfo(BuffInfo other) : this()
		{
			this.dynamicValues_ = other.dynamicValues_.Clone();
			this.lifeTime_ = other.lifeTime_;
			this.addTimeMs_ = other.addTimeMs_;
			this.buffSummonEntityId_ = other.buffSummonEntityId_;
			this.count_ = other.count_;
			this.baseAvatarId_ = other.baseAvatarId_;
			this.buffId_ = other.buffId_;
			this.level_ = other.level_;
			this._unknownFields = UnknownFieldSet.Clone(other._unknownFields);
		}

		// Token: 0x06000F8F RID: 3983 RVA: 0x0002DEA5 File Offset: 0x0002C0A5
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public BuffInfo Clone()
		{
			return new BuffInfo(this);
		}

		// Token: 0x1700049B RID: 1179
		// (get) Token: 0x06000F90 RID: 3984 RVA: 0x0002DEAD File Offset: 0x0002C0AD
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public MapField<string, float> DynamicValues
		{
			get
			{
				return this.dynamicValues_;
			}
		}

		// Token: 0x1700049C RID: 1180
		// (get) Token: 0x06000F91 RID: 3985 RVA: 0x0002DEB5 File Offset: 0x0002C0B5
		// (set) Token: 0x06000F92 RID: 3986 RVA: 0x0002DEBD File Offset: 0x0002C0BD
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public float LifeTime
		{
			get
			{
				return this.lifeTime_;
			}
			set
			{
				this.lifeTime_ = value;
			}
		}

		// Token: 0x1700049D RID: 1181
		// (get) Token: 0x06000F93 RID: 3987 RVA: 0x0002DEC6 File Offset: 0x0002C0C6
		// (set) Token: 0x06000F94 RID: 3988 RVA: 0x0002DECE File Offset: 0x0002C0CE
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public ulong AddTimeMs
		{
			get
			{
				return this.addTimeMs_;
			}
			set
			{
				this.addTimeMs_ = value;
			}
		}

		// Token: 0x1700049E RID: 1182
		// (get) Token: 0x06000F95 RID: 3989 RVA: 0x0002DED7 File Offset: 0x0002C0D7
		// (set) Token: 0x06000F96 RID: 3990 RVA: 0x0002DEDF File Offset: 0x0002C0DF
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint BuffSummonEntityId
		{
			get
			{
				return this.buffSummonEntityId_;
			}
			set
			{
				this.buffSummonEntityId_ = value;
			}
		}

		// Token: 0x1700049F RID: 1183
		// (get) Token: 0x06000F97 RID: 3991 RVA: 0x0002DEE8 File Offset: 0x0002C0E8
		// (set) Token: 0x06000F98 RID: 3992 RVA: 0x0002DEF0 File Offset: 0x0002C0F0
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Count
		{
			get
			{
				return this.count_;
			}
			set
			{
				this.count_ = value;
			}
		}

		// Token: 0x170004A0 RID: 1184
		// (get) Token: 0x06000F99 RID: 3993 RVA: 0x0002DEF9 File Offset: 0x0002C0F9
		// (set) Token: 0x06000F9A RID: 3994 RVA: 0x0002DF01 File Offset: 0x0002C101
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint BaseAvatarId
		{
			get
			{
				return this.baseAvatarId_;
			}
			set
			{
				this.baseAvatarId_ = value;
			}
		}

		// Token: 0x170004A1 RID: 1185
		// (get) Token: 0x06000F9B RID: 3995 RVA: 0x0002DF0A File Offset: 0x0002C10A
		// (set) Token: 0x06000F9C RID: 3996 RVA: 0x0002DF12 File Offset: 0x0002C112
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint BuffId
		{
			get
			{
				return this.buffId_;
			}
			set
			{
				this.buffId_ = value;
			}
		}

		// Token: 0x170004A2 RID: 1186
		// (get) Token: 0x06000F9D RID: 3997 RVA: 0x0002DF1B File Offset: 0x0002C11B
		// (set) Token: 0x06000F9E RID: 3998 RVA: 0x0002DF23 File Offset: 0x0002C123
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Level
		{
			get
			{
				return this.level_;
			}
			set
			{
				this.level_ = value;
			}
		}

		// Token: 0x06000F9F RID: 3999 RVA: 0x0002DF2C File Offset: 0x0002C12C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override bool Equals(object other)
		{
			return this.Equals(other as BuffInfo);
		}

		// Token: 0x06000FA0 RID: 4000 RVA: 0x0002DF3C File Offset: 0x0002C13C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool Equals(BuffInfo other)
		{
			return other != null && (other == this || (this.DynamicValues.Equals(other.DynamicValues) && ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(this.LifeTime, other.LifeTime) && this.AddTimeMs == other.AddTimeMs && this.BuffSummonEntityId == other.BuffSummonEntityId && this.Count == other.Count && this.BaseAvatarId == other.BaseAvatarId && this.BuffId == other.BuffId && this.Level == other.Level && object.Equals(this._unknownFields, other._unknownFields)));
		}

		// Token: 0x06000FA1 RID: 4001 RVA: 0x0002DFF4 File Offset: 0x0002C1F4
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override int GetHashCode()
		{
			int num = 1;
			num ^= this.DynamicValues.GetHashCode();
			if (this.LifeTime != 0f)
			{
				num ^= ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(this.LifeTime);
			}
			if (this.AddTimeMs != 0UL)
			{
				num ^= this.AddTimeMs.GetHashCode();
			}
			if (this.BuffSummonEntityId != 0U)
			{
				num ^= this.BuffSummonEntityId.GetHashCode();
			}
			if (this.Count != 0U)
			{
				num ^= this.Count.GetHashCode();
			}
			if (this.BaseAvatarId != 0U)
			{
				num ^= this.BaseAvatarId.GetHashCode();
			}
			if (this.BuffId != 0U)
			{
				num ^= this.BuffId.GetHashCode();
			}
			if (this.Level != 0U)
			{
				num ^= this.Level.GetHashCode();
			}
			if (this._unknownFields != null)
			{
				num ^= this._unknownFields.GetHashCode();
			}
			return num;
		}

		// Token: 0x06000FA2 RID: 4002 RVA: 0x0002E0DE File Offset: 0x0002C2DE
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override string ToString()
		{
			return JsonFormatter.ToDiagnosticString(this);
		}

		// Token: 0x06000FA3 RID: 4003 RVA: 0x0002E0E6 File Offset: 0x0002C2E6
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void WriteTo(CodedOutputStream output)
		{
			output.WriteRawMessage(this);
		}

		// Token: 0x06000FA4 RID: 4004 RVA: 0x0002E0F0 File Offset: 0x0002C2F0
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalWriteTo(ref WriteContext output)
		{
			if (this.AddTimeMs != 0UL)
			{
				output.WriteRawTag(8);
				output.WriteUInt64(this.AddTimeMs);
			}
			if (this.Level != 0U)
			{
				output.WriteRawTag(24);
				output.WriteUInt32(this.Level);
			}
			this.dynamicValues_.WriteTo(ref output, BuffInfo._map_dynamicValues_codec);
			if (this.BaseAvatarId != 0U)
			{
				output.WriteRawTag(56);
				output.WriteUInt32(this.BaseAvatarId);
			}
			if (this.BuffId != 0U)
			{
				output.WriteRawTag(64);
				output.WriteUInt32(this.BuffId);
			}
			if (this.Count != 0U)
			{
				output.WriteRawTag(80);
				output.WriteUInt32(this.Count);
			}
			if (this.BuffSummonEntityId != 0U)
			{
				output.WriteRawTag(96);
				output.WriteUInt32(this.BuffSummonEntityId);
			}
			if (this.LifeTime != 0f)
			{
				output.WriteRawTag(125);
				output.WriteFloat(this.LifeTime);
			}
			if (this._unknownFields != null)
			{
				this._unknownFields.WriteTo(ref output);
			}
		}

		// Token: 0x06000FA5 RID: 4005 RVA: 0x0002E1EC File Offset: 0x0002C3EC
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public int CalculateSize()
		{
			int num = 0;
			num += this.dynamicValues_.CalculateSize(BuffInfo._map_dynamicValues_codec);
			if (this.LifeTime != 0f)
			{
				num += 5;
			}
			if (this.AddTimeMs != 0UL)
			{
				num += 1 + CodedOutputStream.ComputeUInt64Size(this.AddTimeMs);
			}
			if (this.BuffSummonEntityId != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.BuffSummonEntityId);
			}
			if (this.Count != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Count);
			}
			if (this.BaseAvatarId != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.BaseAvatarId);
			}
			if (this.BuffId != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.BuffId);
			}
			if (this.Level != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Level);
			}
			if (this._unknownFields != null)
			{
				num += this._unknownFields.CalculateSize();
			}
			return num;
		}

		// Token: 0x06000FA6 RID: 4006 RVA: 0x0002E2C8 File Offset: 0x0002C4C8
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(BuffInfo other)
		{
			if (other == null)
			{
				return;
			}
			this.dynamicValues_.MergeFrom(other.dynamicValues_);
			if (other.LifeTime != 0f)
			{
				this.LifeTime = other.LifeTime;
			}
			if (other.AddTimeMs != 0UL)
			{
				this.AddTimeMs = other.AddTimeMs;
			}
			if (other.BuffSummonEntityId != 0U)
			{
				this.BuffSummonEntityId = other.BuffSummonEntityId;
			}
			if (other.Count != 0U)
			{
				this.Count = other.Count;
			}
			if (other.BaseAvatarId != 0U)
			{
				this.BaseAvatarId = other.BaseAvatarId;
			}
			if (other.BuffId != 0U)
			{
				this.BuffId = other.BuffId;
			}
			if (other.Level != 0U)
			{
				this.Level = other.Level;
			}
			this._unknownFields = UnknownFieldSet.MergeFrom(this._unknownFields, other._unknownFields);
		}

		// Token: 0x06000FA7 RID: 4007 RVA: 0x0002E392 File Offset: 0x0002C592
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CodedInputStream input)
		{
			input.ReadRawMessage(this);
		}

		// Token: 0x06000FA8 RID: 4008 RVA: 0x0002E39C File Offset: 0x0002C59C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalMergeFrom(ref ParseContext input)
		{
			uint num;
			while ((num = input.ReadTag()) != 0U)
			{
				if (num <= 56U)
				{
					if (num <= 24U)
					{
						if (num == 8U)
						{
							this.AddTimeMs = input.ReadUInt64();
							continue;
						}
						if (num == 24U)
						{
							this.Level = input.ReadUInt32();
							continue;
						}
					}
					else
					{
						if (num == 50U)
						{
							this.dynamicValues_.AddEntriesFrom(ref input, BuffInfo._map_dynamicValues_codec);
							continue;
						}
						if (num == 56U)
						{
							this.BaseAvatarId = input.ReadUInt32();
							continue;
						}
					}
				}
				else if (num <= 80U)
				{
					if (num == 64U)
					{
						this.BuffId = input.ReadUInt32();
						continue;
					}
					if (num == 80U)
					{
						this.Count = input.ReadUInt32();
						continue;
					}
				}
				else
				{
					if (num == 96U)
					{
						this.BuffSummonEntityId = input.ReadUInt32();
						continue;
					}
					if (num == 125U)
					{
						this.LifeTime = input.ReadFloat();
						continue;
					}
				}
				this._unknownFields = UnknownFieldSet.MergeFieldFrom(this._unknownFields, ref input);
			}
		}

		// Token: 0x04000697 RID: 1687
		private static readonly MessageParser<BuffInfo> _parser = new MessageParser<BuffInfo>(() => new BuffInfo());

		// Token: 0x04000698 RID: 1688
		private UnknownFieldSet _unknownFields;

		// Token: 0x04000699 RID: 1689
		public const int DynamicValuesFieldNumber = 6;

		// Token: 0x0400069A RID: 1690
		private static readonly MapField<string, float>.Codec _map_dynamicValues_codec = new MapField<string, float>.Codec(FieldCodec.ForString(10U, ""), FieldCodec.ForFloat(21U, 0f), 50U);

		// Token: 0x0400069B RID: 1691
		private readonly MapField<string, float> dynamicValues_ = new MapField<string, float>();

		// Token: 0x0400069C RID: 1692
		public const int LifeTimeFieldNumber = 15;

		// Token: 0x0400069D RID: 1693
		private float lifeTime_;

		// Token: 0x0400069E RID: 1694
		public const int AddTimeMsFieldNumber = 1;

		// Token: 0x0400069F RID: 1695
		private ulong addTimeMs_;

		// Token: 0x040006A0 RID: 1696
		public const int BuffSummonEntityIdFieldNumber = 12;

		// Token: 0x040006A1 RID: 1697
		private uint buffSummonEntityId_;

		// Token: 0x040006A2 RID: 1698
		public const int CountFieldNumber = 10;

		// Token: 0x040006A3 RID: 1699
		private uint count_;

		// Token: 0x040006A4 RID: 1700
		public const int BaseAvatarIdFieldNumber = 7;

		// Token: 0x040006A5 RID: 1701
		private uint baseAvatarId_;

		// Token: 0x040006A6 RID: 1702
		public const int BuffIdFieldNumber = 8;

		// Token: 0x040006A7 RID: 1703
		private uint buffId_;

		// Token: 0x040006A8 RID: 1704
		public const int LevelFieldNumber = 3;

		// Token: 0x040006A9 RID: 1705
		private uint level_;
	}
}
